<!DOCTYPE HTML><html><head><title>OpenOCR API API documentation</title><meta http-equiv=X-UA-Compatible content="IE=edge"><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=generator content="https://github.com/kevinrenskers/raml2html 0.30.0"><link rel=stylesheet href=http://netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css><link rel=stylesheet href=http://cdnjs.cloudflare.com/ajax/libs/highlight.js/8.1/styles/default.min.css><script type=text/javascript src=http://code.jquery.com/jquery-1.11.0.min.js></script><script type=text/javascript src=http://netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js></script><script type=text/javascript src=http://cdnjs.cloudflare.com/ajax/libs/highlight.js/8.1/highlight.min.js></script><script type=text/javascript>
        $(document).ready(function() {
            $('.page-header pre code, .top-resource-description pre code').each(function(i, block) {
                hljs.highlightBlock(block);
            });

            $('[data-toggle]').click(function() {
                var selector = $(this).data('target') + ' pre code';
                $(selector).each(function(i, block) {
                    hljs.highlightBlock(block);
                });
            });
        });
    </script><style>
        .hljs {
            background: transparent;
        }
        .parent {
            color: #999;
        }
        .list-group-item > .badge {
            float: none;
            margin-right: 6px;
        }
        .panel-title > .methods {
            float: right;
        }
        .badge {
            border-radius: 0;
            text-transform: uppercase;
            width: 70px;
            font-weight: normal;
            color: #f3f3f6;
            line-height: normal;
        }
        .badge_get {
            background-color: #63a8e2;
        }
        .badge_post {
            background-color: #6cbd7d;
        }
        .badge_put {
            background-color: #22bac4;
        }
        .badge_delete {
            background-color: #d26460;
        }
        .list-group, .panel-group {
            margin-bottom: 0;
        }
        .panel-group .panel+.panel-white {
            margin-top: 0;
        }
        .panel-group .panel-white {
            border-bottom: 1px solid #F5F5F5;
            border-radius: 0;
        }
        .panel-white:last-child {
            border-bottom-color: white;
            -webkit-box-shadow: none;
            box-shadow: none;
        }
        .panel-white .panel-heading {
            background: white;
        }
        .tab-pane ul {
            padding-left: 2em;
        }
        .tab-pane h2 {
            font-size: 1.2em;
            padding-bottom: 4px;
            border-bottom: 1px solid #ddd;
        }
        .tab-pane h3 {
            font-size: 1.1em;
        }
        .tab-content {
            border-left: 1px solid #ddd;
            border-right: 1px solid #ddd;
            border-bottom: 1px solid #ddd;
            padding: 10px;
        }
        #sidebar {
            margin-top: 30px;
        }
        .top-resource-description {
            border-bottom: 1px solid #ddd;
            background: #fcfcfc;
            padding: 15px 15px 0 15px;
            margin: -15px -15px 10px -15px;
        }
        .resource-description {
            border-bottom: 1px solid #fcfcfc;
            background: #fcfcfc;
            padding: 15px 15px 0 15px;
            margin: -15px -15px 10px -15px;
        }
        .panel > .panel-body > .panel-group > .panel:first-child .resource-description {
            display: none;
        }
        .list-group .badge {
            float: left;
        }
        .method_description {
            margin-left: 85px;
        }
        .method_description p:last-child {
            margin: 0;
        }
    </style></head><body data-spy=scroll data-target=#sidebar><div class=container><div class=row><div class=col-md-9 role=main><div class=page-header><h1>OpenOCR API API documentation <small>version v1</small></h1><p>http://openocr.yourserver.co</p></div><div class="panel panel-default"><div class=panel-heading><h3 id=_ocr class=panel-title>/ocr</h3></div><div class=panel-body><div class=panel-group><div class="panel panel-white"><div class=panel-heading><h4 class=panel-title><a class=collapsed data-toggle=collapse href=#panel__ocr><span class=parent></span>/ocr</a> <span class=methods><a href=# data-toggle=modal data-target=#_ocr_post><span class="badge badge_post">post</span></a></span></h4></div><div id=panel__ocr class="panel-collapse collapse"><div class=panel-body><div class=list-group><a href=# data-toggle=modal data-target=#_ocr_post class=list-group-item><span class="badge badge_post">post</span><div class=method_description></div><div class=clearfix></div></a></div></div></div><div class="modal fade" tabindex=0 id=_ocr_post><div class=modal-dialog><div class=modal-content><div class=modal-header><button type=button class=close data-dismiss=modal aria-hidden=true>&times;</button><h4 class=modal-title id=myModalLabel><span class="badge badge_post">post</span> <span class=parent></span>/ocr</h4></div><div class=modal-body><div class="alert alert-info"></div><ul class="nav nav-tabs"><li class=active><a href=#_ocr_post_request data-toggle=tab>Request</a></li><li><a href=#_ocr_post_response data-toggle=tab>Response</a></li></ul><div class=tab-content><div class="tab-pane active" id=_ocr_post_request><h3>Body</h3><p><strong>Type: application/json</strong></p><p><small><strong>Schema</strong>:<pre><code>{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "OpenOCR OCR Processing Request",
    "description": "A request to convert an image into text",
    "type": "object",
    "properties": {
        "img_url": {
            "description": "The URL of the image to process.",
            "type": "string"
        },
        "engine": {
            "description": "The OCR engine to use",
            "enum": [ "tesseract", "go_tesseract", "mock" ]
        },
        "engine_args": {
            "type": "object",
            "description": "The OCR engine arguments to pass (engine-specific)",
	    "properties": {
		"config_vars": {
		    "type": "object",
		    "description": "Config vars - equivalent of -c args to tesseract"
		},
		"psm": {
		    "description": "Page Segment Mode, equivalent of -psm arg to tesseract",
		    "enum": [ "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10" ]
		}
	    },
	    "additionalProperties": false
        }
    },
    "required": ["img_url", "engine"],
    "additionalProperties": false
}
</code></pre></small></p><p><small><strong>Example</strong>:<pre><code>{  
  "img_url":"http://bit.ly/ocrimage",
  "engine":"tesseract",
  "engine_args":{  
    "config_vars":{  
      "tessedit_char_whitelist":"0123456789"
    },
    "psm":"3"
  }
}
</code></pre></small></p></div><div class=tab-pane id=_ocr_post_response><h2>HTTP status code <a href=http://httpstatus.es/200 target=_blank>200</a></h2><h3>Body</h3><p><strong>Type: text/plain</strong></p><p><small><strong>Example</strong>:<pre><code>You can create local variables ..
</code></pre></small></p></div></div></div></div></div></div></div></div></div></div></div><div class=col-md-3><div id=sidebar class="hidden-print affix" role=complementary><ul class="nav nav-pills nav-stacked"><li><a href=#_ocr>/ocr</a></li></ul></div></div></div></div></body></html>